package com.example.ict.controller;

import com.example.ict.common.Result;
import com.example.ict.entity.Ict;
import com.example.ict.service.IctService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 功能：
 * 作者：张传琦
 * 日期：2024-05-06 0:56
 */
@RestController
@RequestMapping("/ictItem")
public class IctController {

    @Autowired
    IctService ictService;

    @PostMapping("/add")
    public Result add(@RequestBody Ict ict){
        ictService.insertIct(ict);
        return Result.success("新增项目成功！",ict);
    }
}
